package com.decent.common.entity.web;

import lombok.Data;
import lombok.ToString;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Update;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * @author: decent Gjh
 * @date: 2022/10/25/16:30
 * @description:
 */
@Data
@ToString
public class User {
    /**
     * 用户id
     */
    @NotNull(message = "请输入用户id ", groups = {Update.class, Delete.class})
    private Integer id;

    /**
     * 用户姓名
     */
    @NotEmpty(message = "name不能为null", groups = {Update.class, Insert.class})
    private String name;

    /**
     * 账户余额
     */
    private BigDecimal money;
}
